<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>预测失败 - 智能气象云平台</title>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet">
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.10.0/font/bootstrap-icons.css">
    <style>
        body {
            background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            padding: 20px;
        }
        .error-container {
            max-width: 600px;
            margin: 0 auto;
        }
        .error-card {
            background: rgba(255, 255, 255, 0.85);
            backdrop-filter: blur(10px);
            border-radius: 20px;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
            overflow: hidden;
            padding: 30px;
            text-align: center;
        }
        .error-icon {
            font-size: 5rem;
            color: #ff6b6b;
            margin-bottom: 20px;
        }
        .error-title {
            font-size: 1.8rem;
            font-weight: 700;
            margin-bottom: 15px;
            color: #333;
        }
        .error-message {
            font-size: 1.1rem;
            color: #555;
            margin-bottom: 25px;
        }
        .back-button {
            margin-top: 20px;
        }
        .data-tip {
            margin-top: 25px;
            padding: 15px;
            background-color: #e9f7fe;
            border-radius: 10px;
            border-left: 4px solid #3498db;
        }
    </style>
</head>
<body>
    <div class="error-container">
        <div class="error-card">
            <div class="error-icon">
                <i class="bi bi-exclamation-triangle"></i>
            </div>
            <h1 class="error-title">无法生成预测</h1>
            <p class="error-message">
                抱歉，无法为 {{ city }} 生成7天天气预报。<br>
                可能是数据不足导致预测失败。
            </p>

            <div class="data-tip">
                <p>
                    <i class="bi bi-lightbulb"></i>
                    小贴士：请尝试采集更多历史数据以提高预测准确性。
                </p>
            </div>

            <div class="d-flex justify-content-center gap-3 mt-4">
                <a href="/api/weather/crawl/{{ city }}" class="btn btn-primary">
                    <i class="bi bi-cloud-download me-2"></i> 采集 {{ city }} 数据
                </a>
                <a href="/api/weather/home" class="btn btn-outline-secondary">
                    <i class="bi bi-house-door me-2"></i> 返回首页
                </a>
            </div>
        </div>
    </div>
</body>
</html>